﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace WY.WebApi.Models.Result
{
    /// <summary>
    /// API返回结果
    /// </summary>
    public class ApiResultBase
    {
        public const string RESULT_OK = "0";
        public const string RESULT_ERROR = "1";

        /// <summary>
        /// API返回结果（0=成功，1=失败）
        /// </summary>
        public string ret { get; set; }
        /// <summary>
        /// API调用失败时的错误原因
        /// </summary>
        public string message { get; set; }

        public ApiResultBase()
        {
            //默认成功
            this.ret = RESULT_OK;
        }
    }
}